package com.yss.adapter;

import com.yss.exception.RemotingException;
import com.yss.exception.RemotingTimeOutException;

import java.io.IOException;

public abstract class IAdapter {

    public IAdapter() {
    }

    public abstract Object handle(AdapterExtraInfo adapterExtraInfo) throws RemotingException, RemotingTimeOutException, IOException;

    public Object runtimeHandle(AdapterExtraInfo adapterExtraInfo) {
        return null;
    }

    public Object sendToKafkaHandle(AdapterExtraInfo adapterExtraInfo) {
        return null;
    }

    public Object sendByRestHandle(AdapterExtraInfo adapterExtraInfo) throws Exception {
        return null;
    }

    public Object sendByNetty(AdapterExtraInfo adapterExtraInfo) throws RemotingException, RemotingTimeOutException {
        return null;
    }

}
